package com.example.demo.pojo;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import lombok.extern.slf4j.Slf4j;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

/**
 * @ClassName: User
 * @Description: 用户类
 * @Author: zzz
 * @Date: 2020-04-04 20:47
 */

@Getter
@Setter
@ToString
@EqualsAndHashCode
@Slf4j
@ApiModel(value = "用户对象")
public class User {

    @ApiModelProperty(value = "用户ID")
    int id;

    @NotNull(message = "age is null")
    int age;
    @NotBlank(message = "name is blank")
    String name;

}
